<template>
  <tr>
    <td>
      <input
        type="number"
        :value="obj.count"
        @input="$emit('add', $event.target.value)"
      />
    </td>
    <td>{{ obj.goodsName }}</td>
    <td>{{ obj.count === 0 ? "卖光了" : "" }}</td>
  </tr>
</template>

<script>
export default {
  props: {
    obj: {
      type: Object,
      required: true,
    },
  },
  data() {
    return {};
  },
};
</script>

<style scoped></style>
